package com.xh.bussiness.permission.service;

import com.xh.bussiness.permission.bean.request.UserRoleRequest;
import com.xh.bussiness.permission.model.Role;
import com.xh.bussiness.permission.model.UserRole;
import com.xh.core.service.IBaseService;

import java.util.List;
import java.util.Map;


public interface IUserRoleService extends IBaseService<UserRole> {


    /**
     *
     * @param userId
     * @return
     */
    public List<Map<String,Object>> queryMenuFunctionsByUserId(String userId);

    List<Role> queryRoleByUserId(String userId);

    List<UserRole> queryUserRoleByUserId(String userId);

    /**
     * 查询用户角色
     * @param bean
     * @return
     */
    public List queryUserRole(UserRoleRequest bean);


    /**
     * 新增用户角色
     * @param bean
     * @return
     */
    public String addUserRole(UserRoleRequest bean);


    /**
     * 修改用户角色
     * @return
     */
    public  String modifyUserRole(UserRoleRequest bean);


    /**
     * 删除用户角色
     * @param id
     * @return
     */
    public String deleteUserRole(String id);

    boolean deleteByUserId(String userId);

}
